<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.css">
    <link rel="stylesheet" href="../static/css/index.css" th:href="@{/css/index.css}">
    <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/font-awesome/css/font-awesome.min.css">
    <!-- 引入 -->
    <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/animate.css/3.7.0/animate.min.css">
    <title>博客首页</title>
</head>
<body>
<!-- 导航 -->
<div class="animated bounceInDown">
    <nav class="ui inverted segment m-padded-td" th:replace="_fragments :: menu(1)">
        <div class="ui container">
            <div class="ui inverted secondary menu">
                <h2 class="ui teal header item" style="font-size: 25px !important;">个人博客</h2>
                <a href="#" th:href="@{/index}" class="active m-item item m-mobile-hide"><i class="home icon"></i>首页</a>
                <a href="#" th:href="@{/type}" class="m-item item m-mobile-hide"><i class="idea icon"></i>分类</a>
                <a href="#" th:href="@{/tages}" class="m-item item m-mobile-hide"><i class="tags icon"></i>标签</a>
                <a href="#" th:href="@{/archives}" class="m-item item m-mobile-hide"><i class="clone icon"></i>归档</a>
                <div class="right item">
                    <div class="ui icon inverted transparent input">
                        <input type="text" placeholder="Search small...">
                        <i class="search link icon"></i>
                    </div>
                </div>
            </div>
        </div>
    </nav>
</div>
<!-- 中间 -->
<div  class="m-container-small m-padded-tb-big">
    <div class="ui container">
        <!--header-->
        <div class="ui top attached segment">
            <div class="ui middle aligned two column grid">
                <div class="column">
                    <h3 class="ui teal header">搜索结果</h3>
                </div>
                <div class="right aligned column">
                    共 <h2 class="ui orange header m-inline-block m-text-thin" th:text="${pageInfo.total}"> 14 </h2> 个
                </div>
            </div>
        </div>



        <div class="ui top attached teal segment" th:each="blog : ${pageInfo.list}">
            <div class="ui padded vertical segment m-padded-tb-large">
                <div class="ui middle aligned mobile reversed stackable grid" >
                    <div class="eleven wide column">
                        <h3 class="ui header" ><a href="#" th:href="@{/blog/{id}(id=${blog.id})}" target="_blank" class="m-black" th:text="${blog.title}">你真的理解什么是财富自由吗?</a></h3>
                        <p class="m-text" th:text="|${blog.description}......|">正确做好任何一件事情的前提是清晰、正确的理解目标。而事实是，我们很多人很多时候根本没有对目标正确的定义，甚至根本从来就没有想过，只是大家都那么做而已…...</p>
                        <div class="ui grid">
                            <div class="eleven wide column">
                                <div class="ui mini horizontal link list">
                                    <div class="item">
                                        <img src="https://unsplash.it/100/100?image=1005" th:src="@{${blog.avatar}}"  alt="" class="ui avatar image">
                                        <div class="content"><a href="#" class="header" th:text="${blog.nickname}" >李仁密</a></div>
                                    </div>
                                    <div class="item">
                                        <i class="calendar icon"></i><span th:text="${blog.updateTimeStr}">2017-10-01</span>
                                    </div>
                                    <div class="item">
                                        <i class="eye icon"></i> <span th:text="${blog.views}">2342</span>
                                    </div>
                                </div>
                            </div>
                            <div class="right aligned five wide column">
                                <a href="#" target="_blank" class="ui teal basic label m-padded-tiny m-text-thin" th:text="${blog.typeName}">认知升级</a>
                            </div>
                        </div>
                    </div>

                    <div class="five wide column">
                        <a href="#" th:href="@{/blog/{id}(id=${blog.id})}" target="_blank">
                            <img src="https://unsplash.it/800/450?image=1005" th:src="@{${blog.firstPicture}}"  alt="" class="ui rounded image">
                        </a>
                    </div>

                </div>
            </div>
        </div>
        <!--footer-->
    </div>
</div>
<br>
<br>
<br>
<br>
<!-- 底部 -->
<footer th:replace="_fragments :: footer" class="ui inverted vertical segment m-padded-tb-massive">
    <div class="ui center aligned container">
        <div class="ui inverted divided stackable grid">
            <div class="four wide column">
                <div class="ui inverted link list">
                    <div class="item">
                        <img src="../static/images/weixin.png" th:src="@{/images/weixin.png}" class="ui rounded image" alt="" style="width: 110px">
                    </div>
                </div>
            </div>
            <div class="four wide column">
                <h4 class="ui inverted header m-text-thin m-text-spaced ">联系我</h4>
                <div class="ui inverted link list">
                    <a  class="item m-text-thin">843808107@qq.com</a>
                    <a  class="item m-text-thin">QQ：843808107</a>
                </div>
            </div>
            <div class="eight wide column">
                <h4 class="ui inverted header m-text-thin m-text-spaced ">Blog</h4>
                <p class="m-text-thin m-text-spaced m-opacity-mini" style="font-size: 15px; color:darkgray;">这是我的个人博客，会分享关于编程、写作、思考相关的内容，希望可以给来到这儿的人有所帮助~</p>
            </div>
        </div>
        <div class="ui inverted link horizontal list">
            <a class="item m-text-thin" style="vertical-align: middle" href="http://icp.chinaz.com/info?q=kevintam.cn" target="_blank">
                <span>备案/许可证号：鄂ICP备19030178号</span>
            </a>
            <a class="item m-text-thin" style="vertical-align: middle" href="http://www.beian.miit.gov.cn/" target="_blank">
                <span>鄂ICP备19030178号-1</span>
            </a>
        </div>
</footer>
</canvas>

<!-- waifu-tips.js 依赖 JQuery 库 -->
<script src="../static/assets/jquery-1.11.0.min.js" th:src="@{/assets/jquery-1.11.0.min.js}"></script>

<!-- 实现拖动效果，需引入 JQuery UI -->
<script src="../static/assets/jqueryUi.js" th:src="@{/assets/jqueryUi.js}"></script>
<script src="../static/assets/autoload.js" th:src="@{/assets/autoload.js}"></script>
<script src="https://cdn.jsdelivr.net/npm/jquery@3.2/dist/jquery.min.js"></script>
<script src="https://cdn.jsdelivr.net/semantic-ui/2.2.4/semantic.min.js"></script>
<script src="//cdn.jsdelivr.net/npm/jquery.scrollto@2.1.2/jquery.scrollTo.min.js"></script>
<script src="../static/js/ribbon.min.js" th:src="@{/js/ribbon.min.js}"></script>
<script>

    window.onload = function () {
        var pageNumber = 0;
        console.log(pageNumber);
        var aList = $('#pageBtns').children();
        console.log(aList);
        for (var i = 0; i < aList.length; i++) {
            var a = aList[i];
            if(a.text == (pageNumber + 1)){
                $(a).toggleClass('basic');
            }
        }
    };

    $('.menu.toggle').click(function () {
        $('.m-item').toggleClass('m-mobile-hide');
    });
    $('.wechat').popup({
        popup : $('.wechat-qr'),
        position: 'bottom center'
    });
    $('.zheng').popup({
        popup : $('.zheng-qr'),
        position: 'bottom center'
    });
    $('.qq').popup();
    $('.github').popup();
</script>
</body>
</html>